<include file="Public:header" />
<script type="text/javascript" src="__PUBLIC__/admin/js/engine.js"></script>
<script type="text/javascript" src="__PUBLIC__/admin/js/jq_validate.js"></script>
<script type="text/javascript">
$(function(){
	$('#keywords').validate('required','请填网站关键词').validate();
    $('#url').validate('required','请填网站地址').validate('url','地址不正确，请以http://开头').validate();
	$('#dataForm').submitValidate();	
});
</script>
<body class="mainBackground">
	<include file="Public:menu" />
	<div class="main" id="mainContainer">
        <!--发布-->
    	<div class="content_box">
        	<div class="content_box_t">
            	<h3 class="fl">
                <neq name="data[id]" value=''>
                编辑<else/>新增</neq>链接
                </h3>
            </div>
            <div class="content_box_c">
            	<form action="__ACTION__" method="post" id="dataForm" name="dataForm" enctype="multipart/form-data">
                    <div class="field">
                        <label>网站类型</label>
                        <select name="type" class="public_dropdown small_input" id="type" type="select-one">
                            <volist name="types" id="vo">
                                <option value="{$key}" <eq name="key" value="$data[type]">selected</eq>
                                />{$vo}</option>
                            </volist>
                        </select>
                    </div>                                         
                	<div class="field pt15">
						<label>网站关键词</label>
						<input class="text_input w20_input" type="text" name="keywords" id="keywords" value="{$data.keywords}" />
                        <span class="input_notification  png_bg" id="keywordsTip"></span>
						<small>必填</small>
					</div>
                    <div class="field pt15">
                        <label>网站地址</label>
                        <input class="text_input w20_input" type="text" name="url" id="url" value="{$data.url}" />
                        <span class="input_notification  png_bg" id="urlTip"></span>
                        <small>必填(以'http://'开头)</small>
                    </div>                    
                    <div class="field pt15">
                        <label>LOGO</label>
                        <input class="text_input medium_input" type="file" name="pic" id="pic"/>
                        <small>(图片格式：jpg,gif,png)</small>
                    </div>                                          
                	<div class="field pt15">
						<label>网站描述</label>
						<textarea class="text_input" name="introduce" id="introduce" cols="79" rows="5">{$data.introduce}</textarea>
					</div>
                    <div class="field pt15">
                        <label>联系人</label>
                        <input class="text_input w20_input" type="text" name="username" id="username" value="{$data.username}" />
                    </div>                     
                	<div class="field pt15">
						<label>是否开放</label>
						<input type="checkbox" name="status"  value="1" <eq name="data.status" value="1"> checked</eq>/>是 
                        <small>默认开放</small>
					</div>                                                                                             
                    <div class="field pt15 clearfix">
                    	<input type="hidden" name="id" value="{$data.id}"/>   
                    	<input type="submit" value="提交" class="public_button fr" />
                    </div>                                                                               
                </form>
            </div>
        </div>            
        <!--发布结束-->
    </div>
</body>
</html>
